Open
Conversation
- Update Pipfile dependencies to resolve compatibility issues - Remove deprecated black config option (skip-numeric-underscore-normalization) - Add E704 to flake8 ignore list for compatibility with black's stub formatting - Fix type annotation in postgres_client.py: change params: dict = None to params: Optional[dict] = None to satisfy mypy's no_implicit_optional - Apply black and isort formatting to existing files All linting checks (flake8, mypy, black, isort) now pass.
- Update mock paths in test_postgres_handler.py from tentaclio.clients.postgres_client to tentaclio_postgres.clients.postgres_client (the correct module path for this plugin package) - Update conftest.py to import tentaclio_postgres instead of using tentaclio.clients, since PostgresClient is not part of the base tentaclio package All 13 unit tests now pass.
- Add docker-compose.yml for local PostgreSQL testing environment - Add explicit db_client.conn.commit() calls after set_schema() and delete_schema() in test fixtures to ensure schema changes are visible to other database connections - Add pytest.mark.skipif decorators to gracefully skip tests when PostgreSQL is not configured locally Root cause: Schema changes (CREATE TABLE, DROP TABLE) were not being committed to the database, so when tentaclio.open() created a new connection, it couldn't see the tables created by the test fixture, causing "relation does not exist" errors. All 15 functional tests now pass when run with local PostgreSQL via docker-compose.
- Update PostgreSQL connection string to include password authentication: postgresql://circleci:testpassword@localhost:5432/tentaclio-db - Set POSTGRES_PASSWORD in postgres container environment - Install postgresql-client in CI for database readiness checks - Add wait-for-postgres step to ensure database is ready before running tests The functional tests were timing out in CI because: 1. The connection string didn't include authentication credentials 2. Tests ran before PostgreSQL was fully initialized With these changes, the functional tests run successfully in CI with proper password authentication instead of relying on trust-based authentication.
366e1d5 to
0bb4d91
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR fixes linting errors, unit test failures, and functional test issues that were preventing the CI pipeline from passing. Also adds a local Docker Compose environment for easier development and testing.
Changes